Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> flash->php->tworzenie pliku xml
awariat
post
Post #1





Grupa: Zarejestrowani
Postów: 37
Pomógł: 0
Dołączył: 21.06.2008

Ostrzeżenie: (0%)
-----


z flasza wysyłam zmienną

...zmiennaXML =<books>
<book publisher="Addison-Wesley" name="Design Patterns" />
<book publisher="Addison-Wesley" name="The Pragmatic Programmer" />
<book publisher="Addison-Wesley" name="Test Driven Development" />
<book publisher="Addison-Wesley" name="Refactoring to Patterns" />
<book publisher="O'Reilly Media" name="The Cathedral & the Bazaar" />
<book publisher="O'Reilly Media" name="Unit Test Frameworks" />
</books>;




w php tworze sobie plik xml

<?php
extract ( $_POST );
$dane= "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n".$zmiennaXML;
$file = "param.xml";
...

a wynik jest taki

<?xml version="1.0" encoding="utf-8"?>
<books>
<book publisher=\"Addison-Wesley\" name=\"Design Patterns\"/>
<book publisher=\"Addison-Wesley\" name=\"The Pragmatic Programmer\"/>
<book publisher=\"Addison-Wesley\" name=\"Test Driven Development\"/>
<book publisher=\"Addison-Wesley\" name=\"Refactoring to Patterns\"/>
<book publisher=\"O\'Reilly Media\" name=\"The Cathedral &amp; the Bazaar\"/>
<book publisher=\"O\'Reilly Media\" name=\"Unit Test Frameworks\"/>
</books>


jak zlikwidowac te "kreski" (IMG:http://forum.php.pl/style_emoticons/default/blinksmiley.gif) ?
dzieki

może mozna zadeklarowac ze ta zmienna jest xml czy co
Go to the top of the page
+Quote Post
ddiceman
post
Post #2





Grupa: Zarejestrowani
Postów: 326
Pomógł: 121
Dołączył: 23.07.2008
Skąd: Wrocław

Ostrzeżenie: (0%)
-----


stripslashes()
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 23.08.2025 - 20:50